﻿#ifndef SOFTWARELIST_H
#define SOFTWARELIST_H

#include <QtGui>
#include <QtSql>
#include "mydatamodel.h"


namespace Ui {
class softwareList;
}

class softwareList : public QFrame
{
    Q_OBJECT
    
public:
    explicit softwareList(QWidget *parent = 0);
    ~softwareList();

public slots:
    void updateList();

    
private:
    Ui::softwareList *ui;
    QString getQuery();
    myDataModel *dbModel;

    enum{
        SDB_enumber,
        SDB_client,
        SDB_software,
        SDB_quantity,
        SDB_date,
        SDB_comment

    };
private slots:
    void	scurrentRowChanged ( const QModelIndex & current, const QModelIndex & previous );

    void on_addButton_clicked();
    void on_delsearchButton_clicked();
    void on_searchButton_clicked();
    void on_searchEdit_returnPressed();
    void on_changeButton_clicked();
    void on_printButton_clicked();
};

#endif // SOFTWARELIST_H
